home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
C/C++ Users Group Library 1996 July
/
C-C++ Users Group Library July 1996.iso
/
listings
/
v_10_08
/
1008078a
< prev
next >
Wrap
Text File
|
1991-12-02
|
573b
|
30 lines
// refitem.hpp
// declaration of RefCntItem -
// a RefCntPtr must point to
// a class derived from this one,
// or to a class that implements
// the same functions
#ifndef CLASS_RefCntItem
#define CLASS_RefCntItem
class RefCntItem
{
private:
unsigned int p_refCnt;
public:
RefCntItem (void)
: p_refCnt(0)
{};
void incRefCnt (void)
{ ++p_refCnt;};
void decRefCnt (void)
{ --p_refCnt;};
unsigned int refCnt (void)
{ return p_refCnt;};
virtual ~RefCntItem (void) {};
};
#endif